<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title><?php if($meta_title != ''): echo ($meta_title); ?>-<?php endif; echo C('website.title');?></title>
<meta name="keywords" content="<?php echo C('website.keywords');?>"/>
<meta name="description" content="<?php echo C('website.desc');?>"/>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="/public/Home/dist/css/zui.css">
<link rel="stylesheet" href="/public/Home/dist/css/zui-theme.css">
<link rel="stylesheet" href="/public/Home/common/css/style.css">
<script type="text/javascript" src="/public/Home/dist/lib/jquery/jquery.js"></script>
<script type="text/javascript" src="/public/Home/dist/js/zui.js"></script>
<script type="text/javascript" src="/public/Home/dist/lib/layer/layer.js"></script>
<link rel="stylesheet" type="text/css" href="/public/Home/assets/css/simditor.css" />
<script type="text/javascript" src="/public/Home/assets/js/module.min.js"></script>
<script type="text/javascript" src="/public/Home/assets/js/hotkeys.min.js"></script>
<script type="text/javascript" src="/public/Home/assets/js/uploader.min.js"></script>
<script type="text/javascript" src="/public/Home/assets/js/simditor.min.js"></script>


</head>
<body>
<div class="header-index-fix"></div>
<div class="header">
    <div class="container-fixed">
        <div class="header-left">
            <a href="#"><img src="<?php echo getImgidpath(C('website.logo'));?>" alt=""></a>
        </div>
        <div class="header-right">
            <ul class="header-nav">
                <li <?php if($mark == 'index'): ?>class="active"<?php endif; ?>>
                    <a href="<?php echo U('index/index');?>">项目大厅</a>
                </li>
                <li <?php if($mark == 'rank'): ?>class="active"<?php endif; ?>>
                    <a href="<?php echo U('rank/index');?>">排行榜</a>
                </li>
                <li <?php if($mark == 'article'): ?>class="active"<?php endif; ?>>
                    <a href="<?php echo U('article/index');?>">资讯</a>
                </li>
                <li <?php if($mark == 'company'): ?>class="dropdown dropdown-hover active"<?php else: ?>class="dropdown dropdown-hover"<?php endif; ?>>
                    <a href="#" data-toggle="dropdown">企业服务 <span class="drop-arrow"></span></a>
                    <ul class="dropdown-menu drop-nav">
                        <li>
                            <a href="<?php echo U('bug/index');?>">漏洞认领</a>
                        </li>
                        <li>
                            <a href="<?php echo U('company/index');?>">入驻企业</a>
                        </li>
                    </ul>
                </li>
                <li class="dropdown dropdown-hover">
                    <a href="#" data-toggle="dropdown">白帽服务 <span class="drop-arrow"></span></a>
                    <ul class="dropdown-menu drop-nav">
                        <li>
                            <a href="<?php echo U('index/index');?>">技术知识分享</a>
                        </li>
                        <li>
                            <a href="<?php echo U('index/index');?>">等级与福利</a>
                        </li>
                    </ul>
                </li>
                <li>
                    <a href="<?php echo U('bbs/index');?>">论坛</a>
                </li>
            </ul>
            <div class="header-user">
                <div class="user-btns">
                    <div class="dropdown">
                        <button class="btn btn-primary" type="button" data-toggle="dropdown">提交 <span class="caret"></span></button>
                        <ul class="dropdown-menu pull-right">
                            <li><a href="<?php echo U('bug/post');?>">提交漏洞</a></li>
                            <li class="divider"></li>
                            <li><a href="<?php echo U('project/post');?>">提交项目</a></li>
                        </ul>
                    </div>
                </div>
                <div class="user-login">
                    <?php if($_SESSION['user']== null): ?><a href="<?php echo U('user/login');?>">登录</a>
                    <a href="<?php echo U('user/register');?>">注册</a>
                    <?php else: ?>
                        <a href="<?php echo U('user/member');?>"><?php echo ($_SESSION['user']['username']); ?></a><?php endif; ?>
                </div>
            </div>
        </div>
    </div>
</div>


    <div class="main">
        <div class="banner">
            <div class="container-fixed">
                <div class="banner-box">
                    <h2>项目大厅</h2>
                    <hr>
                    <p>在这里，你可以看到所有厂商发布的项目，每天都有新的项目在发布着。</p>
                </div>
            </div>
        </div>
        <div class="project">
            <ul class="project-classify">
                <li <?php if($type == '0'): ?>class="active"<?php endif; ?>><a href="<?php echo U('index/index',array('type'=>0));?>">全部</a></li>
                <?php if(is_array($types)): $i = 0; $__LIST__ = $types;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): $mod = ($i % 2 );++$i;?><li <?php if($type == $vo['id']): ?>class="active"<?php endif; ?>><a href="<?php echo U('index/index',array('type'=>$vo['id']));?>"><?php echo ($vo["title"]); ?></a></li><?php endforeach; endif; else: echo "" ;endif; ?>
            </ul>
            <div class="project-main">
                <div class="project-loading" style="display:block">
                    <span></span>
                    <span></span>
                    <span></span>
                    <span></span>
                    <span></span>
                </div>
                <div class="project-list">
                    <div class="container-fixed">
                        <div class="row">
                            <?php if(is_array($projects)): $i = 0; $__LIST__ = $projects;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): $mod = ($i % 2 );++$i;?><div class="col-xs-4">
                                    <div class="project-box">
                                        <?php if($vo['ishot'] == '1'): ?><div class="project-box-hot"></div><?php endif; ?>
                                        <div class="project-box-num">No.<?php echo ($vo["id"]); ?></div>
                                        <div class="project-box-pic">
                                            <a href="<?php echo U('project/detail',array('id'=>$vo['id']));?>" target="_blank">
                                                <img src="<?php echo (getImgidpath($vo["cover"])); ?>" alt="">
                                            </a>
                                        </div>
                                        <h4><a href="<?php echo U('project/detail',array('id'=>$vo['id']));?>" target="_blank"><?php echo ($vo["title"]); ?></a></h4>
                                        <p><?php echo ($vo["mintroduce"]); ?></p>
                                        <div class="project-box-detail">
                                            <div class="detail-time">
                                                期限：<?php echo ($vo["start_time"]); ?> - <?php echo ($vo["end_time"]); ?>
                                            </div>
                                            <div class="detail-level">
                                                <span>奖金等级：</span>
                                                <span class="level-stars text-warning">
                                                    <?php $__FOR_START_5334__=1;$__FOR_END_5334__=$vo['grade']+1;for($i=$__FOR_START_5334__;$i < $__FOR_END_5334__;$i+=1){ ?><i class="icon icon-star"></i><?php } ?>
                                                </span>
                                            </div>
                                            <?php switch($vo["status"]): case "1": ?><a href="<?php echo U('project/detail',array('id'=>$vo['id']));?>" target="_blank" class="detail-btn btn-on">进行中</a><?php break;?>
                                                <?php case "2": ?><a href="<?php echo U('project/detail',array('id'=>$vo['id']));?>" target="_blank" class="detail-btn">暂停中</a><?php break;?>
                                                <?php case "3": ?><a href="javascript:;" class="detail-btn btn-over">暂停中</a><?php break; endswitch;?>
                                        </div>
                                    </div>
                                </div><?php endforeach; endif; else: echo "" ;endif; ?>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>

<div class="footer">
    <div class="container">
        <div class="footer-list">
            <ul>
                <li><a href="<?php echo U('index/index');?>" target="_blank">项目大厅</a></li>
                <li><a href="<?php echo U('rank/index');?>" target="_blank">排行榜</a></li>
                <li><a href="<?php echo U('user/index');?>" target="_blank">个人主页</a></li>
                <li><a href="#" target="_blank">帮助中心</a></li>
            </ul>
        </div>

        <div class="footer-bom">
        	<div>
        		 <?php echo C('website.recard');?>	<span>&nbsp;&nbsp;&nbsp;&nbsp;</span>  <?php echo C('website.copyright');?>
        	</div>
        </div>
    </div>
</div>


</body>
</html>